package com.cql.controller;

import com.RestTemplateHystrixEurekaClient;
import com.cql.service.RestTemplateHystrixService;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;


@RestController
@RequestMapping("/instance")
public class RestTemplateHystrixController {
    private static final Logger logger = LoggerFactory.getLogger(RestTemplateHystrixController.class);

    @Autowired
    private RestTemplateHystrixService restTemplateHystrixService;



    @GetMapping("/cql")
    public String test(){
        return restTemplateHystrixService.ask();
    }

//    @RequestMapping(value = "feign/{name}", method = RequestMethod.GET)
//    public String sayHello2(@PathVariable("name") String name) {
//        return restTemplateHystrixService.sayHello2(name);
//    }
}
